package com.example.springboot.service;

import cn.hutool.json.JSONObject;
import com.baomidou.mybatisplus.extension.service.IService;
import com.example.springboot.entity.Borrow;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;

import java.io.Serializable;
import java.util.Collection;
import java.util.List;

public interface IBorrowService extends IService<Borrow> {

    boolean save(Borrow entity);

    boolean updateById(Borrow entity);

    boolean removeById(Borrow entity);

    boolean removeBatchByIds(Collection<?> list);

    List<Borrow> list();

    Borrow getById(Serializable id);

    <E extends IPage<Borrow>> E page(E page, Wrapper<Borrow> queryWrapper);

    JSONObject borrowCount();

    JSONObject borrowEcharts();
}

